package fun.zhaoyuanhao.facai.gen;

import java.util.LinkedList;
import java.util.List;

/**
 * 种子生成器
 *
 * @author 赵元昊
 * @date 2021/09/03 17:46
 **/
public class SeedGen {

    public static List<Integer> gen(Integer start, Integer end) {
        List<Integer> seed = new LinkedList<>();
        if (end.compareTo(start) >= 0) {
            for (int i = start; i <= end; i++) {
                seed.add(i);
            }
            return seed;
        }
        throw new RuntimeException(String.format("end '%s' not less than start '%s'", end, start));
    }
}
